/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

package org.apli.haiam.ejb.entidades;

import java.io.Serializable;
import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.NamedQueries;
import javax.persistence.NamedQuery;
import javax.persistence.Table;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;

/**
 *
 * @author Informática
 */
@Entity
@Table(name = "hos_evolucion_tipoevo")
@NamedQueries({
    @NamedQuery(name = "HosEvolucionTipoevo.findAll", query = "SELECT h FROM HosEvolucionTipoevo h")})
public class HosEvolucionTipoevo implements Serializable {
    private static final long serialVersionUID = 1L;
    @Id
    @Basic(optional = false)
    @NotNull
    @Column(name = "het_id")
    private Integer hetId;
    @Size(max = 2147483647)
    @Column(name = "het_observacion")
    private String hetObservacion;
    @JoinColumn(name = "hte_id", referencedColumnName = "hte_id")
    @ManyToOne(fetch = FetchType.LAZY)
    private HosTipoEvolucion hosTipoEvolucion;
    @JoinColumn(name = "hev_id", referencedColumnName = "hev_id")
    @ManyToOne(fetch = FetchType.LAZY)
    private HosEvolucion hosEvolucion;

    public HosEvolucionTipoevo() {
    }

    public HosEvolucionTipoevo(Integer hetId) {
        this.hetId = hetId;
    }

    public Integer getHetId() {
        return hetId;
    }

    public void setHetId(Integer hetId) {
        this.hetId = hetId;
    }

    public String getHetObservacion() {
        return hetObservacion;
    }

    public void setHetObservacion(String hetObservacion) {
        this.hetObservacion = hetObservacion;
    }

    public HosTipoEvolucion getHosTipoEvolucion() {
        return hosTipoEvolucion;
    }

    public void setHosTipoEvolucion(HosTipoEvolucion hosTipoEvolucion) {
        this.hosTipoEvolucion = hosTipoEvolucion;
    }

    public HosEvolucion getHosEvolucion() {
        return hosEvolucion;
    }

    public void setHosEvolucion(HosEvolucion hosEvolucion) {
        this.hosEvolucion = hosEvolucion;
    }

    @Override
    public int hashCode() {
        int hash = 0;
        hash += (hetId != null ? hetId.hashCode() : 0);
        return hash;
    }

    @Override
    public boolean equals(Object object) {
        // TODO: Warning - this method won't work in the case the id fields are not set
        if (!(object instanceof HosEvolucionTipoevo)) {
            return false;
        }
        HosEvolucionTipoevo other = (HosEvolucionTipoevo) object;
        if ((this.hetId == null && other.hetId != null) || (this.hetId != null && !this.hetId.equals(other.hetId))) {
            return false;
        }
        return true;
    }

    @Override
    public String toString() {
        return "org.apli.haiam.ejb.entidades.HosEvolucionTipoevo[ hetId=" + hetId + " ]";
    }
    
}
